package com.hsj.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.web.client.RestTemplate;

@Service
public class OrderServiceImplUseRestTemplate {
    @Autowired
    private RestTemplate restTemplate;
    public String getOrder(){
        String orderInfo =  "order info";
        String user = restTemplate.getForObject("http://127.0.0.1:8082/getuser", String.class);
        return orderInfo+"用户信息："+user;
    }



}
